﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="ViewStatePropertyTest._Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>View State Property Test Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <h3>
        Ref: <a href="http://www.cnblogs.com/cry/archive/2010/01/31/1660641.html">http://www.cnblogs.com/cry/archive/2010/01/31/1660641.html</a>
    </h3>
    <div>
        <h1>
            ViewState["DefaultUserName"]:
            <%=ViewState["DefaultUserName"] %></h1>
        <h1>
            ViewState["CustomUserName"]:
            <%=ViewState["CustomUserName"]%></h1>
        <h1>
            ViewState["MyUserID"]:
            <%=null == ViewState["MyUserID"] ? 0 : (int)ViewState["MyUserID"] %></h1>
    </div>
    </form>
</body>
</html>
